<?php

declare (strict_types=1);
/**
 * @copyright 深圳市易果网络科技有限公司
 * @version 1.0.0
 * @link https://dayiguo.com
 */

namespace App\Controller\user;

use App\Dao\VersionDao;
use Hyperf\Di\Annotation\Inject;
use Hyperf\HttpServer\Annotation\AutoController;
use Hyperf\HttpServer\Annotation\Middleware;

/**
 * APP版本控制器
 *
 * @AutoController()
 * @author 张昊(2396675557@qq.com)
 * @package App\Controller\admin
 */
class VersionController extends Controller
{
    /**
     * @Inject
     * @var VersionDao
     */
    private $version_dao;


    /**
     * 版本对比
     */
    public function client()
    {
        $client = (int)$this->request->input('client', 0);

        $result = $this->version_dao->find($client);

        $this->success($result);
    }
}